/*
 * wordsearcher.c
 *
 *  Created on: 21.10.2011
 *      Author: David
 */

#include "wavePlayer.h"
#include "integer.h"
#include "typedef.h"
#include "pff.h"
#include "tools.h"
#include <stdlib.h>
#include <string.h>

#define TEMP_MINUS 0b10000000

extern FRESULT play (
		const char *dir,	/* Directory */
		const char *fn		/* File */
	);

/**
 *
 */
void vPlayTemperature(u8 u8Temperature)
{
	FRESULT res;
	char tmp[15];

/*	if((u8Temperature & TEMP_MINUS) == TEMP_MINUS)
	{
		res = play("", "minus");		 Play file
	}

	u8Temperature &= U8_INVERT((u8)TEMP_MINUS);*/

	itoa(u8Temperature, tmp, 10);
	strcat((char*)tmp, ".wav");

	res = play("wav", tmp);		/* Play file */
	//res = play("", "jednotky");		/* Play file */
}
